import axios from 'axios';
import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import CourseHome from './views/CourseHome.vue'
//系统设置
import orgmanage from './views/system/orgmanage.vue'
import usermanage from './views/system/usermanage.vue'




var routes=[
    {
        path: '/login',
        component: Login,
        name: '登录',
        meta:{ role:'index'},
        hidden: true
    },     
    {
        path: '/',
        component: Home,
        name: '系统设置',
        iconCls: 'iconfont icon-ziyuanshezhi',
        meta:{ role:'admin',home:'resource'},
        children: [
            { path: '/orglist', component: orgmanage, name: '机构管理' ,hidden:false},        
            { path: '/user', component: usermanage, name: '用户管理',hidden:false},
        ]
    },   
    {
        path: '/',
        component: Home,
        name: '系统设置',
        iconCls: 'iconfont icon-ziyuanshezhi',
        meta:{ role:'manager',home:'resource'},
        children: [
            { path: '/user', component: usermanage, name: '用户管理',hidden:false},
        ]
    },     
    {
        path: '*',
        hidden: true,
        meta:{ role:'*'},
        redirect: { path: '/404' }
    }
];

export default routes;